home *** CD-ROM | disk | FTP | other *** search
/ Sprite 1984 - 1993 / Sprite 1984 - 1993.iso / src / machserver / 1.098 / include / stddef.h < prev    next >
C/C++ Source or Header  |  1990-10-26  |  892b  |  38 lines

  1. /*
  2.  * stddef.h --
  3.  *
  4.  *    Declarations of standard types.
  5.  *
  6.  * Copyright 1989 Regents of the University of California
  7.  * Permission to use, copy, modify, and distribute this
  8.  * software and its documentation for any purpose and without
  9.  * fee is hereby granted, provided that the above copyright
  10.  * notice appear in all copies.  The University of California
  11.  * makes no representations about the suitability of this
  12.  * software for any purpose.  It is provided "as is" without
  13.  * express or implied warranty.
  14.  *
  15.  * $Header: /sprite/src/lib/include/RCS/stddef.h,v 1.4 90/10/19 15:41:25 shirriff Exp $
  16.  */
  17.  
  18. #ifndef _STDDEF
  19. #define _STDDEF
  20.  
  21. typedef int ptrdiff_t;
  22. typedef short wchar_t;
  23.  
  24. #ifndef _SIZE_T
  25. #define _SIZE_T
  26. typedef int size_t;
  27. #endif
  28.  
  29. #ifndef NULL
  30. #define    NULL        0
  31. #endif
  32.  
  33. #define offsetof(structtype, field) \
  34.     ((size_t)(char *)&(((structtype *)0)->field))
  35.  
  36. #endif /* _STDDEF */
  37.  
  38.